]> dgit.raspbian.org Git - gnome-shell.git/commit
shell/window-tracker: Match on WM_CLASS first
authorFlorian Müllner <fmuellner@gnome.org>
Fri, 3 Jul 2020 15:34:23 +0000 (17:34 +0200)
committerGeorges Basile Stavracas Neto <georges.stavracas@gmail.com>
Mon, 6 Jul 2020 14:59:51 +0000 (14:59 +0000)
commitf29dbd1f187fc78f0afc938faee7f7f2713635c4
tree47d77c0d0ff97ae3d6cf96c6aef74707e7a7c9f5
parentb60836932ad6339b54c4af19ce1f41a57a83013d
shell/window-tracker: Match on WM_CLASS first

Currently our heuristics for matching a window to its app check
for the application ID before the WM_CLASS, as the ID is more
reliable in so far that it is outside the application's control
and so it cannot use it to spoof a different application.

However this also prevents applications with multiple .desktop
files like LibreOffice from matching any .desktop files other
than the one under the main ID.

Since we now no longer allow the WM_CLASS to match a .desktop
file that doesn't belong to the sandboxed application, we can
fix that issue by checking the WM_CLASS first, without opening
the door to spoofing.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/219
src/shell-window-tracker.c